<%@ include file="../abrirEvento.jsp" %>

<%
    String menssagem;

    try{
        String name = request.getParameter("name") != null ? request.getParameter("name") : "";
        String email = request.getParameter("enviaEmail") != null ? request.getParameter("enviaEmail") : "";
        String website = request.getParameter("website") != null ? request.getParameter("website") : "";
        String message = request.getParameter("message") != null ? request.getParameter("message")  : "";

        Persistente objContatoSite = new Persistente("ContatoSite");
        objContatoSite.setString("nome",name);
        objContatoSite.setString("email",email);
        objContatoSite.setString("webSite",website);
        objContatoSite.setString("menssagem",message);
        objContatoSite.setPersistente("evento",objEvento);
        objContatoSite.invocarMetodo("Salvar");
        menssagem = "Mensagem Enviada com sucesso...";

    }catch(Exception ex){
        menssagem = ex.getMessage();
    }
%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <title><%=tituloPagina%></title>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
    <link href="css/style.css" rel="stylesheet" type="text/css"/>
    <link rel="stylesheet" type="text/css" href="css/coin-slider.css"/>
    <script type="text/javascript" src="js/cufon-yui.js"></script>
    <script type="text/javascript" src="js/cufon-georgia.js"></script>
    <script type="text/javascript" src="js/jquery-1.4.2.min.js"></script>
    <script type="text/javascript" src="js/script.js"></script>
    <script type="text/javascript" src="js/coin-slider.min.js"></script>
</head>
<body>
<div class="main">
<%@ include file="cabecalho.jsp" %>
<div class="content">
    <div class="content_resize">
        <div class="mainbar">
            <div class="article">
                <h2><span>Seu Contato</span></h2>
            </div>
            <div class="article">
                <div class="clr"></div>
                <%=menssagem.replace("@quebraLinha@","<br>")%>
            </div>
        </div>
        <div class="sidebar">
            <%@ include file="menu.jsp" %>
            <%@ include file="apoio.jsp" %>
        </div>
        <div class="clr"></div>
    </div>
</div>
<%@ include file="rodape.jsp" %>
<%@ include file="copyright.jsp" %>
</div>
</body>
</html>
